package test;

import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;

@ManagedBean
@SessionScoped
public class Usuario {
	private String user;
	private String pass;
	private String errorLogueo;



	public String login(){
		if(user.equalsIgnoreCase("user") && pass.equalsIgnoreCase("123")){
			return "bienvenido";
		}else{
			this.setErrorLogueo("User incorrecto :/");
			return "";
		}	
	}

	public String getPass() {
		return pass;
	}
	public void setPass(String pass) {
		this.pass = pass;
	}
	public String getUser() {
		return user;
	}
	public void setUser(String user) {
		this.user = user;
	}
	public String getErrorLogueo() {
		return errorLogueo;
	}
	public void setErrorLogueo(String errorLogueo) {
		this.errorLogueo = errorLogueo;
	}
}
